package com.ocm.core.factory;

import com.ocm.core.service.AssociationTypeService;
import com.ocm.core.service.JCRSecurityService;

public class ObjectFactory {

   private static OCMFactory ocmFactory;

   public static AssociationTypeService getOneToOne(){
      return ocmFactory.getOneToOne();
   }

   public static AssociationTypeService getOneToMultiple(){
      return ocmFactory.getOneToMultiple();
   }

   public static AssociationTypeService getOneToMultipleDescOrderation(){
      return ocmFactory.getOneToMultipleDescOrderation();
   }

   public static JCRSecurityService getJCRSecurityService(){
      return ocmFactory.getJCRSecurityService();
   }

   static {
      if (ocmFactory == null){
         ocmFactory = new OCMFactoryImpl();
      }
   }
}
